<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8" %>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@page isELIgnored="false" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
    <base href="<%=basePath%>">
    <meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/>
    <title>商品列表页</title>
    <link rel="stylesheet" href="render/css/frontend/common/base.css" type="text/css"/>
    <link rel="stylesheet" href="render/css/frontend/common/shop_common.css" type="text/css"/>
    <link rel="stylesheet" href="render/css/frontend/shop_header.css" type="text/css"/>
    <link rel="stylesheet" href="render/css/frontend/shop_list.css" type="text/css"/>
    <style type="text/css">
        .shop_bd_list_content{
            min-height: 584px;
        }
    </style>

    <script type="text/javascript" src="render/js/jquery.min.js"></script>
</head>
<body>
<!-- Header Start -->
<jsp:include page="common/head.jsp"></jsp:include>

<!-- TopHeader Center -->
<jsp:include page="common/topheader_center.jsp"></jsp:include>
<!-- TopHeader Center End -->

<!-- Header Menu -->
<jsp:include page="common/header_menu.jsp"></jsp:include>
<!-- Header Menu End -->

<div class="shop_hd_breadcrumb">
    <strong>当前位置：</strong>
    <span>
        <a href="/">首页</a>&nbsp;›&nbsp;
<%--        <a href="/render/myhome">个人中心</a>&nbsp;›&nbsp;--%>
        <a href="javascript:void(0);">商品列表页</a>
    </span>
</div>
<div class="clear"></div>
<!-- 面包屑 End -->
<!-- Header End -->


<!-- List Body -->
<div class="shop_bd clearfix">
    <div class="shop_bd_list_left clearfix">
        <!-- 热卖推荐商品 -->
        <div class="shop_bd_list_bk clearfix">
            <div class="title">热卖推荐商品</div>
            <div class="contents clearfix">
                <ul class="clearfix">
                    <c:if test="${!empty product_sale_count}">
                        <c:forEach items="${product_sale_count}" var="product" begin="0" end="1">
                            <li class="clearfix">
                                <div class="goods_name">
                                    <a href="/render/product/product_detail?id=${product.id}">${product.name}</a>
                                </div>
                                <div class="goods_pic">
                                    <span class="goods_price">¥ ${product.price} </span>
                                    <a href="/render/product/product_detail?id=${product.id}">
                                        <img src="${product.main_image}"/>
                                    </a>
                                </div>
                                <div class="goods_xiaoliang">
                                    <span class="goods_xiaoliang_link"><a href="/render/product/product_detail?id=${product.id}">去看看</a></span>
                                    <span class="goods_xiaoliang_nums">已销售<strong>${product.sale_count}</strong>笔</span>
                                </div>
                            </li>
                        </c:forEach>
                    </c:if>
                </ul>
            </div>
        </div>
        <!-- 热卖推荐商品 -->
        <div class="clear"></div>
    </div>

    <div class="shop_bd_list_right clearfix">
        <c:if test="${!empty pb}">
            <jsp:include page="common/product_list.jsp"></jsp:include>
        </c:if>
        <c:if test="${empty pb}">
            <jsp:include page="common/shop_list.jsp"></jsp:include>
        </c:if>
    </div>
</div>
<!-- List Body End -->

<!-- Footer - wll -->
<jsp:include page="common/footer.jsp"></jsp:include>
<!-- Footer End -->
</body>
</html>













<!-- 左边商品分类:获取第二级别下面的第三级别，
场景模拟：
情景1：点击所有分类的第三级别，获取它的父类以及兄弟。
情景2：点击所有分类的第二级别，获取它的父类以及子类。
情景3：点击所有父类的第一级别，获取它的子类以及子类的子类。
（情景三有点特殊，它上面就出现第三级别分类，优先实现情景1、2）-->
<%--<div class="shop_bd_list_bk clearfix">
    <div class="title">商品分类</div>
    <div class="contents clearfix">
        <dl class="shop_bd_list_type_links clearfix">
            &lt;%&ndash;获取特定分类，父类特定map，子类循环list。&ndash;%&gt;
            <dt><strong>${category.name}</strong></dt>
            <dd class="category_dd">
                <c:forEach items="${categories}" var="Categories">
                    <span id="category_a"><a href="javascript:void(0);">${Categories.name}</a></span>
                </c:forEach>
            </dd>
        </dl>
    </div>
</div>--%>
<!-- 左边商品分类 End -->


<!-- 浏览过的商品 感觉redis记录来查询-->
<%--<div class="shop_bd_list_bk clearfix">
    <div class="title">浏览过的商品</div>
    <div class="contents clearfix">
        <ul class="clearfix">

            <li class="clearfix">
                <div class="goods_name">
                    <a href="">Gap经典弹力纯色长袖T恤|000891347|原价149元</a>
                </div>
                <div class="goods_pic">
                    <span class="goods_price">¥ 279.00 </span><a href="">
                    <img src="render/images/89a6d6466b00ae32d3c826b9ec639084.jpg_small.jpg"/></a></div>
                <div class="goods_xiaoliang">
                    <span class="goods_xiaoliang_link"><a href="">去看看</a></span>
                    <span class="goods_xiaoliang_nums">已销售<strong>99</strong>笔</span>
                </div>
            </li>

        </ul>
    </div>
</div>--%>
<!-- 浏览过的商品 -->